.class Lcom/waiqin365/lightapp/kaoqin/ad;
.super Ljava/lang/Object;

# interfaces
.implements Landroid/view/View$OnClickListener;


# instance fields
.field final synthetic a:Lorg/json/JSONObject;

.field final synthetic b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;


# direct methods
.method constructor <init>(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;Lorg/json/JSONObject;)V
    .locals 0

    iput-object p1, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    iput-object p2, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->a:Lorg/json/JSONObject;

    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method


# virtual methods
.method public onClick(Landroid/view/View;)V
    .locals 4

    iget-object v0, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    const/4 v1, 0x1

    invoke-virtual {v0, v1}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->a(Z)Z

    move-result v0

    if-nez v0, :cond_0

    :goto_0
    return-void

    :cond_0
    new-instance v1, Landroid/content/Intent;

    iget-object v0, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    invoke-static {v0}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->j(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;)Landroid/content/Context;

    move-result-object v0

    const-class v2, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinCheckActy;

    invoke-direct {v1, v0, v2}, Landroid/content/Intent;-><init>(Landroid/content/Context;Ljava/lang/Class;)V

    const-string/jumbo v0, "btnsJSON"

    iget-object v2, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->a:Lorg/json/JSONObject;

    invoke-virtual {v2}, Lorg/json/JSONObject;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    new-instance v2, Lorg/json/JSONObject;

    invoke-direct {v2}, Lorg/json/JSONObject;-><init>()V

    :try_start_0
    iget-object v0, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    invoke-static {v0}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->e(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;)Ljava/lang/String;

    move-result-object v0

    invoke-static {v0}, Landroid/text/TextUtils;->isEmpty(Ljava/lang/CharSequence;)Z

    move-result v0

    if-nez v0, :cond_1

    const-string/jumbo v0, "data_id"

    iget-object v3, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    invoke-static {v3}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->e(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    :goto_1
    const-string/jumbo v0, "form_id"

    iget-object v3, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    invoke-static {v3}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->g(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    const-string/jumbo v0, "form_data"

    iget-object v3, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    iget-object v3, v3, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->a:Lorg/json/JSONObject;

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    const-string/jumbo v0, "approval_mode"

    const-string/jumbo v3, ""

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    const-string/jumbo v0, "ccs"

    const-string/jumbo v3, ""

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    const-string/jumbo v0, "is_filish"

    const-string/jumbo v3, ""

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    const-string/jumbo v0, "opinion"

    const-string/jumbo v3, ""

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;

    const-string/jumbo v0, "tab_type"

    iget-object v3, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    invoke-static {v3}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->h(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
    :try_end_0
    .catch Lorg/json/JSONException; {:try_start_0 .. :try_end_0} :catch_0

    :goto_2
    const-string/jumbo v0, "updataJSON"

    invoke-virtual {v2}, Lorg/json/JSONObject;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v0, v2}, Landroid/content/Intent;->putExtra(Ljava/lang/String;Ljava/lang/String;)Landroid/content/Intent;

    iget-object v0, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    const/16 v2, 0x7897

    invoke-virtual {v0, v1, v2}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->startActivityForResult(Landroid/content/Intent;I)V

    goto/16 :goto_0

    :cond_1
    :try_start_1
    const-string/jumbo v0, "flow_id"

    iget-object v3, p0, Lcom/waiqin365/lightapp/kaoqin/ad;->b:Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;

    invoke-static {v3}, Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;->f(Lcom/waiqin365/lightapp/kaoqin/NewKaoQinApplyActy;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v0, v3}, Lorg/json/JSONObject;->put(Ljava/lang/String;Ljava/lang/Object;)Lorg/json/JSONObject;
    :try_end_1
    .catch Lorg/json/JSONException; {:try_start_1 .. :try_end_1} :catch_0

    goto :goto_1

    :catch_0
    move-exception v0

    invoke-virtual {v0}, Lorg/json/JSONException;->printStackTrace()V

    goto :goto_2
.end method
